package com.globalresources.business.inface;

import java.io.IOException;
import java.text.ParseException;
import java.util.List;

import com.globalresources.commons.vo.FileWrapper;
import com.globalresources.po.City;
import com.globalresources.po.Hospital;

/**
 * @author aaron.lu(luzhiyuan) E-mail:atyuan.lu@gmail.com
 * @since 创建时间：Jul 26, 2009 9:31:04 AM
 */
public interface IFileOperatorService {

	public String getHospitalPath();
	
	public String getUserPath();
	
	/**
	 * <P>剪切文件到指定文件下
	*@author aaron.lu(luzhiyuan)
	*@param absoultFilePath
	*@param userId
	*@param documentName
	*@return
	*@throws IOException
	 */
	public boolean moveFile(String absoultFilePath, Integer userId, String documentName) throws IOException;
	
	/**
	 * <p>分隔文件
	*@author aaron.lu(luzhiyuan)
	*@param path
	*@param tofrom
	*@param toend
	*@return
	 */
	public boolean splitFile(String path, int tofrom, int toend);
	
	/**
	 * 备份文件
	*@author aaron.lu(luzhiyuan)
	*@param path
	*@return
	 */
	public boolean backupFile(String path);
	
	/**
	 * <p>查询医院列表
	*@author aaron.lu(luzhiyuan)
	*@return
	 */
	public List<Hospital> getHospitals();
	
	/**
	 * <p>查询城市列表
	*@author aaron.lu(luzhiyuan)
	*@return
	 */
	public List<City> getCities();
	
	/**
	 * <p>遍历文件夹，读所有文档信息
	*@author aaron.lu(luzhiyuan)
	*@return List
	*@throws ParseException
	 */
	public List<FileWrapper> getAllFilesUnProcess() throws ParseException;
	
	/**
	 * <p>获得文件夹下所有文档
	*@author aaron.lu(luzhiyuan)
	*@param folder
	*@return
	*@throws ParseException
	 */
	public List<FileWrapper> getAllFilesUnderFloder(String folder) throws ParseException;

}
